package com.njwb.controller;

import com.njwb.json.ResponseResult;
import com.njwb.pojo.Dept;
import com.njwb.service.DeptService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class DeptController {
    @Autowired
    private DeptService deptService;
    @PostMapping("dept")
    public ResponseResult add(Dept dept){
        deptService.add(dept);
        return ResponseResult.success();
    }
}